
var EventConfig = cc.Class({
    extend:Object,
    properties:{
        global:require('Global'),
        platformId:-1,
    
    },
    ctor:function(){
        this.platformId = (cc.sys.os === cc.sys.OS_IOS ? 11 : 10);
        this.eventMap = {};
        this.constructorMap();
    },
    constructorMap:function(){
       
        // this.eventMap.set(platform,this.platformId+'');

        //游戏内部通用统计
        var innergame = ['充值','游戏内（菜单)','游戏说明','摩托介绍','支持记录','关闭音乐','返回大厅'];
        var inneractionId = ['7015','7016','7017','7018','7019','7020','7021'];
        for (var i = 0; i < innergame.length; i++){
            var actionName = innergame[i];
            var actionId = inneractionId[i];
            this.eventMap[actionName]=actionId;
        }

        //游戏分类统计
        //热血摩托
        var  motoActions = ['哈雷','宝马','杜卡迪','雅马哈','本田','投注项（100)','投注项（1000)','投注项（10000)','投注项（50000)','撤销','赛况','车况','历史'];
        for (var i = 0; i < motoActions;i++){
            var moto = motoActions[i];
            var motoId = 7001+i;
            this.eventMap[moto]=this.platformId+''+motoId;
        }
    },
    
    getEventId:function(eventName){
        return this.eventMap[eventName];
    },
    display(){
        cc.log(this.eventMap);
    }

});

module.exports = EventConfig;
window.EventConfig = new EventConfig();


